/*
 * Copyright (c) 2020-2021 HiSilicon (Shanghai) Technologies CO., LIMITED.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 * Description: crc interfaces.
 * Date: 2021-04-13
 */

#include <soc_crc.h>
#include "crc.h"

td_u16 uapi_crc16(td_u16 crc_start, TD_CONST td_u8 *buf, td_u32 len)
{
    return crc16_ccitt(crc_start, buf, len);
}

td_u32 uapi_crc32(td_u32 crc_start, TD_CONST td_u8 *buf, td_u32 len)
{
    return crc32(crc_start, buf, len);
}

td_u32 uapi_crc32_no_comp(td_u32 crc_start, TD_CONST td_u8 *buf, td_u32 len)
{
    return crc32_no_comp(crc_start, buf, len);
}
